SRC =      report

LATEX =    latex
BIBTEX =   bibtex
PDFLATEX = pdflatex

ARG = -file-line-error

all:	pdf 

cleanup:
	-rm -f *.aux
	-rm -f *.toc
	-rm -f *.snm
	-rm -f *.nav
	-rm -f *.out
	-rm -f *.log
	-rm -f *.lof
	-rm -f *.bbl
	-rm -f *.blg
	-rm -f *.brf
	-rm -f *.idx
	-rm -f *.loa
	-rm -f *.lot
	-rm -f figures/*.log figures/*.mp figures/*.mpo figures/*.tmp

clean:	cleanup
	-rm -f *.dvi
	-rm -f *.ps
	-rm -f $(SRC).pdf

view:
	kpdf $(SRC).pdf &

pdf:	
	$(PDFLATEX) $(ARG) $(SRC) doxygen.sty
	$(BIBTEX) $(SRC)
	$(PDFLATEX) $(ARG) $(SRC)


jpg:
	convert -geometry 100% $(SRC).pdf $(SRC).jpg

debug:
	echo $(TEXINPUTS)
	$(LATEX) -version
